package com.jeecg.jing.controller;

import com.jeecg.jing.entity.ZTakeinEntity;
import org.jeecgframework.core.common.controller.BaseController;
import org.jeecgframework.core.common.model.json.DataGrid;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * 客户利息
 */
@Controller
@RequestMapping("/lixiController")
public class LiXiController extends BaseController {
	private static final Logger logger = LoggerFactory.getLogger(LiXiController.class);

	@Autowired
	private ControllerUtil controllerUtil;

	@RequestMapping(params = "list")
	public ModelAndView list(HttpServletRequest request) {
		return controllerUtil.list(request);
	}

	@RequestMapping(params = "datagrid")
	public void datagrid(ZTakeinEntity zTakein,HttpServletRequest request, HttpServletResponse response, DataGrid dataGrid) {
		controllerUtil.datagrid(zTakein, request, response, dataGrid);
	}

	/**
	 * 导出excel
	 */
	@RequestMapping(params = "exportXls")
	public String exportXls(ZTakeinEntity zTakein,HttpServletRequest request,HttpServletResponse response
			, DataGrid dataGrid,ModelMap modelMap) throws Exception {
		return controllerUtil.exportXls(zTakein, request, dataGrid, modelMap);
	}
}
